package edu.gatech.mobile.scene.provider.impl;

import android.net.Uri;
import edu.gatech.mobile.scene.provider.TableSchema;

/**
 * Specifying ImageInfo table schema
 * @author Jing
 *
 */

public class ImageInfoTable extends TableSchema {
	
	private static final String TABLE_NAME = "images";

	// Base MIME type for the entity table.
	private static final String TABLE_TYPE = "vnd.en.images";

	public static final Uri CONTENT_URI = Uri.parse("content://"
			+ ProprioVisionSchema.AUTHORITY + "/images");
	
	public static final String SORT_ORDER = "time_posted ASC";

	//Table columns
	public static final String TIME_POSTED = "time_posted";
	public static final String FILE_NAME = "file_name";
	public static final String LATITUDE = "latitude";
	public static final String LONGITUDE = "longitude";
	public static final String ALTITUDE = "altitude";
	public static final String ACCELEROMETER_X = "accelerometer_x";
	public static final String ACCELEROMETER_Y = "accelerometer_y";
	public static final String ACCELEROMETER_Z = "accelerometer_z";
	public static final String USE= "use";
	public static final String HORIZON_LEFT_X = "horizon_left_x";
	public static final String HORIZON_LEFT_Y = "horizon_left_y";
	public static final String HORIZON_RIGHT_X = "horizon_right_x";
	public static final String HORIZON_RIGHT_Y = "horizon_right_y";
	
	public static final String ORIENTATION_AZIMUTH = "orientation_azimuth";
	public static final String ORIENTATION_PITCH = "orientation_pitch";
	public static final String ORIENTATION_ROLL = "orientation_roll";
	public static final String MAGNETIC_X = "mag_x"; 
	public static final String MAGNETIC_Y = "mag_y";	
	public static final String MAGNETIC_Z = "mag_z";
	public static final String FOCAL_LENGTH = "focal_length";
	public static final String WHITE_BALANCE = "white_balance";
	public static final String EXPOSURE_TIME = "exposure_time";
	public static final String ISO_RATING = "iso";
	public static final String APERTURE = "aperture";
	public static final String CAMERA_PARAMS = "camera_params";
	
	//Specifying data type for each column
	private static final String[][] FIELDS = {{TIME_POSTED, "REAL"}, {FILE_NAME, "TEXT"},{USE, "INTEGER"}, 
		{LATITUDE, "REAL"}, {LONGITUDE, "REAL"}, {ALTITUDE, "REAL"}, 
		{ACCELEROMETER_X, "REAL"}, {ACCELEROMETER_Y, "REAL"}, {ACCELEROMETER_Z, "REAL"}, 
		{HORIZON_LEFT_X, "INTEGER"}, {HORIZON_LEFT_Y, "INTEGER"},{HORIZON_RIGHT_X, "INTEGER"},{HORIZON_RIGHT_Y, "INTEGER"},
		{ORIENTATION_AZIMUTH, "REAL"}, {ORIENTATION_PITCH, "REAL"}, {ORIENTATION_ROLL, "REAL"},
		{MAGNETIC_X, "REAL"}, {MAGNETIC_Y, "REAL"}, {MAGNETIC_Z, "REAL"}, 
		{FOCAL_LENGTH, "REAL"}, {WHITE_BALANCE, "INTEGER"}, {EXPOSURE_TIME, "REAL"}, {ISO_RATING, "INTEGER"}, {APERTURE, "REAL"},
		{CAMERA_PARAMS, "TEXT"}
		};
	
	protected ImageInfoTable() {
		super(TABLE_NAME, TABLE_TYPE, CONTENT_URI, SORT_ORDER, FIELDS);
	}
	
}
